// 问题件接口
import request from '@/utils/request'

// 查询问题件列表
export const listPiece = function (data) {
  return request({
    url: 'order/problemPiece/selectSysProblemPieceDetailList',
    method: 'post',
    data,
  })
}

// 查询问题件详细
export const editPiece = function (data) {
  return request({
    url: 'system/problemPiece/edit',
    method: 'put',
    data,
  })
}

export const problemPieceDetails = function (data) {
  return request({
    url: 'order/problemPiece/selectSysProblemPieceDetails',
    method: 'post',
    data,
  })
}

export const handlingProblemPieces = function (data) {
  return request({
    url: 'order/problemPiece/handlingProblemPieces',
    method: 'put',
    data,
  })
}

export const batchHandlingProblemPieces = function (data) {
  return request({
    url: 'order/problemPiece/batchHandlingProblemPieces',
    method: 'put',
    data,
  })
}
// 下载索赔书
export const downloadProblemPiece = function (id) {
  return request({
    url: `order/problemPiece/downloadProblemPiece/${ id }`,
    method: 'get',
  })
}
